package com.woniu.search.entity;

import org.springframework.data.annotation.Id;
import org.springframework.data.elasticsearch.annotations.Document;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

/**
 * @author 杨光 微信号:tolryg
 * @time 11:58
 */
@Document(indexName = "cinema",type = "cinema")
public class CinemaSearch {

    private static final long serialVersionUID = 1L;

    @Field(type = FieldType.Text, index = true)
    private String searchText;


    /**
     * 电影院id
     */
    @Id
    @Field(type = FieldType.Long, index = true)
    private Integer cinemaId;

    /**
     * 电影院名称
     */
    @Field(type = FieldType.Keyword, index = false)
    private String cinemaName;

    /**
     * 电话
     */
    @Field(type = FieldType.Keyword, index = false)
    private String cinemaPhone;

    /**
     * 详细地址
     */
    @Field(type = FieldType.Keyword, index = false)
    private String cinemaLocation;


    public String getSearchText() {
        return searchText;
    }

    public void setSearchText(String searchText) {
        this.searchText = searchText;
    }
    public Integer getCinemaId() {
        return cinemaId;
    }

    public void setCinemaId(Integer cinemaId) {
        this.cinemaId = cinemaId;
    }

    public String getCinemaName() {
        return cinemaName;
    }

    public void setCinemaName(String cinemaName) {
        this.cinemaName = cinemaName;
    }

    public String getCinemaPhone() {
        return cinemaPhone;
    }

    public void setCinemaPhone(String cinemaPhone) {
        this.cinemaPhone = cinemaPhone;
    }

    public String getCinemaLocation() {
        return cinemaLocation;
    }

    public void setCinemaLocation(String cinemaLocation) {
        this.cinemaLocation = cinemaLocation;
    }

    @Override
    public String toString() {
        return "CinemaSearch{" +
                "searchText='" + searchText + '\'' +
                ", cinemaId=" + cinemaId +
                ", cinemaName='" + cinemaName + '\'' +
                ", cinemaPhone='" + cinemaPhone + '\'' +
                ", cinemaLocation='" + cinemaLocation + '\'' +
                '}';
    }
}

